import 'package:fluro/fluro.dart';
import 'package:flutter_app/pages/home_page.dart';
import 'package:flutter_app/pages/login_page.dart';

class Routers {
  static const root = '/';
  static const home = '/home';
  static const weather = '/weather';
  static const provinces = '/provinces';
  static const cities = '/cities';
  static const districts = '/districts';
  static const setting = '/setting';

  static configureRouters(FluroRouter routers) {
    routers.notFoundHandler = _notFoundHandler;
    routers.define(root, handler: _loginPage);
    routers.define(home, handler: _homePage);
  }

  static Handler _notFoundHandler = Handler(handlerFunc: (context, param) {
    print('Not Found Router');
    return null;
  });

  static Handler _loginPage =
  Handler(handlerFunc: (context, param) => LoginPage());

  static Handler _homePage = Handler(
      handlerFunc: (context, param) => HomePage());

}
